Skip to content

Steer file navigation to Glob/LS instead of find#32

Merged
gobetti merged 1 commit into
mainfrom
steer-file-nav-to-glob
Jul 10, 2026
Merged

Steer file navigation to Glob/LS instead of find#32
gobetti merged 1 commit into
mainfrom
steer-file-nav-to-glob

Conversation

@gobetti

@gobetti gobetti commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Description

On large monorepos, reviews spend turns on denied find calls — locating files, listing directories, and the cross-app consistency sweeps the review prompt explicitly asks for ("search the rest of the codebase for similar implementations"). Reproducing an ht-platform review three times, every permission denial was find (8/8 across runs; zero git-subcommand or toolchain denials); the production job that prompted this logged 16, all the same shape. The run still passed — these are wasted turns absorbed by the budget — but they're pure waste.

Unlike grep/jq/ls, find can't be added to the allow-list: find -exec and -delete execute and mutate files, which breaks the read-only contract. The legitimate need — locating and listing files — is already served read-only by the Glob and LS tools. So this steers the model to those and states find is unavailable, so it stops probing.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)

Testing Done

Prompt-only change to the shared review workflow; no functional/schema change. Validated the YAML parses. Root cause confirmed by reproducing an ht-platform PR review locally three times under the CI allow-list — all denials were find; will confirm the reduction on live reviews.

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my code
  • I have added tests that prove my fix/feature works
  • New and existing tests pass locally
  • I have updated documentation as needed

On large monorepos, reviews spend turns on denied `find` calls —
locating files, listing directories, and cross-app consistency
sweeps the review prompt asks for. A reproduced ht-platform review
hit permission denials that were entirely `find`; on one run the
production job logged 16, all of the same shape.

find can't be allow-listed the way grep/jq/ls were: `find -exec` and
`-delete` execute and mutate, so it breaks the read-only contract.
The legitimate need — locating and listing files — is already served
read-only by the Glob and LS tools. Point the model at those and note
find is unavailable, so it stops probing and wasting turns.

@jaysonv0341 jaysonv0341 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@gobetti gobetti merged commit a76ecc5 into main Jul 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants